package com.example.bugshaker;

import com.example.bugshaker.email.AppTest;
import com.example.mybugshaker.ActivityReferenceManager;
import com.example.mybugshaker.BugShaker;
import ohos.aafwk.ability.Ability;
import org.junit.Before;
import org.junit.Test;

import static org.junit.Assert.*;

public class ActivityReferenceManagerTest {

    ActivityReferenceManager activityReferenceManager = new ActivityReferenceManager();

    @Before
    public void setUp() throws Exception {
        activityReferenceManager.setActivity(AppTest.currentTopAbility);
    }

    @Test
    public void getValidatedActivity() {
         Ability AA = activityReferenceManager.getValidatedActivity();
        assertSame(AppTest.currentTopAbility, AA);
    }
}